﻿using DamageNumbersPro;
using Gp.Scripts.Core;
using TMPro;
using UnityEngine;

namespace Gp.Scripts.GUI.VFX {
    public class FloatingText : DamageNumber {
        private const string RightTemplate = "{0}/{1}";
        private static readonly Vector3 Offset = new(0, 1, 0); 
        public void SpawnText(Vector3 pos, int damageAmount) {
             this.Spawn(pos + Offset, damageAmount);
            // spawn.left.text = damageAmount.ToString();
            // spawn.right.text = "";
                // string.Format(RightTemplate, res.AttackHard.ToString(), res.DefenceIntensity);
            //
            // if (res.Critical && res.IsHit) {
            //     spawn.left.fontSize *= 1.2f;
            // }
            
        }
    }
}